.class Lcom/android/inputmethod/latin/GoogleVoiceManager$6;
.super Landroid/speech/IRecognitionListener$Stub;
.source "GoogleVoiceManager.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/android/inputmethod/latin/GoogleVoiceManager;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;


# direct methods
.method constructor <init>(Lcom/android/inputmethod/latin/GoogleVoiceManager;)V
    .locals 0
    .parameter

    .prologue
    .line 414
    iput-object p1, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-direct {p0}, Landroid/speech/IRecognitionListener$Stub;-><init>()V

    return-void
.end method


# virtual methods
.method public onBeginningOfSpeech()V
    .locals 2

    .prologue
    .line 379
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    const/4 v1, 0x0

    iput-boolean v1, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mSpeechEnded:Z

    .line 380
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v1, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v1}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$800(Lcom/android/inputmethod/latin/GoogleVoiceManager;)Ljava/io/ByteArrayOutputStream;

    move-result-object v1

    invoke-virtual {v1}, Ljava/io/ByteArrayOutputStream;->size()I

    move-result v1

    invoke-static {v0, v1}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$702(Lcom/android/inputmethod/latin/GoogleVoiceManager;I)I

    .line 381
    return-void
.end method

.method public onBufferReceived([B)V
    .locals 3
    .parameter "buf"

    .prologue
    .line 411
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v0}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$800(Lcom/android/inputmethod/latin/GoogleVoiceManager;)Ljava/io/ByteArrayOutputStream;

    move-result-object v0

    const/4 v1, 0x0

    array-length v2, p1

    invoke-virtual {v0, p1, v1, v2}, Ljava/io/ByteArrayOutputStream;->write([BII)V

    .line 412
    return-void
.end method

.method public onEndOfSpeech()V
    .locals 2

    .prologue
    .line 388
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    const/4 v1, 0x1

    iput-boolean v1, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mSpeechEnded:Z

    .line 389
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mHandler:Landroid/os/Handler;

    iget-object v1, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v1}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$100(Lcom/android/inputmethod/latin/GoogleVoiceManager;)Ljava/lang/Runnable;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V

    .line 390
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mHandler:Landroid/os/Handler;

    new-instance v1, Lcom/android/inputmethod/latin/GoogleVoiceManager$6$2;

    invoke-direct {v1, p0}, Lcom/android/inputmethod/latin/GoogleVoiceManager$6$2;-><init>(Lcom/android/inputmethod/latin/GoogleVoiceManager$6;)V

    invoke-virtual {v0, v1}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    .line 396
    return-void
.end method

.method public onError(I)V
    .locals 1
    .parameter "error"

    .prologue
    .line 415
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-virtual {v0, p1}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->onError(I)V

    .line 416
    return-void
.end method

.method public onReadyForSpeech(Landroid/os/Bundle;)V
    .locals 1
    .parameter "bundle"

    .prologue
    .line 372
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v0}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$600(Lcom/android/inputmethod/latin/GoogleVoiceManager;)V

    .line 373
    return-void
.end method

.method public onResults(Ljava/util/List;J)V
    .locals 4
    .parameter
    .parameter "key"
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/util/List",
            "<",
            "Landroid/speech/RecognitionResult;",
            ">;J)V"
        }
    .end annotation

    .prologue
    .line 359
    .local p1, results:Ljava/util/List;,"Ljava/util/List<Landroid/speech/RecognitionResult;>;"
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mContext:Lcom/android/inputmethod/latin/LatinIME;

    iget-object v1, v0, Lcom/android/inputmethod/latin/LatinIME;->mHandler:Landroid/os/Handler;

    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mContext:Lcom/android/inputmethod/latin/LatinIME;

    iget-object v2, v0, Lcom/android/inputmethod/latin/LatinIME;->mHandler:Landroid/os/Handler;

    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mContext:Lcom/android/inputmethod/latin/LatinIME;

    const/4 v3, 0x3

    const/4 v0, 0x0

    invoke-interface {p1, v0}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Landroid/speech/RecognitionResult;

    iget-object v0, v0, Landroid/speech/RecognitionResult;->mText:Ljava/lang/String;

    invoke-virtual {v2, v3, v0}, Landroid/os/Handler;->obtainMessage(ILjava/lang/Object;)Landroid/os/Message;

    move-result-object v0

    invoke-virtual {v1, v0}, Landroid/os/Handler;->sendMessage(Landroid/os/Message;)Z

    .line 360
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    iget-object v0, v0, Lcom/android/inputmethod/latin/GoogleVoiceManager;->mHandler:Landroid/os/Handler;

    new-instance v1, Lcom/android/inputmethod/latin/GoogleVoiceManager$6$1;

    invoke-direct {v1, p0}, Lcom/android/inputmethod/latin/GoogleVoiceManager$6$1;-><init>(Lcom/android/inputmethod/latin/GoogleVoiceManager$6;)V

    invoke-virtual {v0, v1}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    .line 365
    return-void
.end method

.method public onRmsChanged(F)V
    .locals 2
    .parameter "rmsdB"

    .prologue
    .line 402
    iget-object v0, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v0}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$1000(Lcom/android/inputmethod/latin/GoogleVoiceManager;)[Ljava/lang/Byte;

    move-result-object v0

    monitor-enter v0

    .line 403
    :try_start_0
    iget-object v1, p0, Lcom/android/inputmethod/latin/GoogleVoiceManager$6;->this$0:Lcom/android/inputmethod/latin/GoogleVoiceManager;

    invoke-static {v1, p1}, Lcom/android/inputmethod/latin/GoogleVoiceManager;->access$1102(Lcom/android/inputmethod/latin/GoogleVoiceManager;F)F

    .line 404
    monitor-exit v0

    .line 405
    return-void

    .line 404
    :catchall_0
    move-exception v1

    monitor-exit v0
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    throw v1
.end method
